# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=kapidox
pkgver=5.73.0
pkgrel=0
arch="noarch !armhf" # armhf blocked by extra-cmake-modules
pkgdesc="Scripts and data for building API documentation (dox) in a standard format and style"
url="https://community.kde.org/Frameworks"
license="BSD-3-Clause"
depends="python3 py3-yaml py3-jinja2 doxygen"
makedepends="extra-cmake-modules python3-dev"
source="https://download.kde.org/stable/frameworks/${pkgver%.*}/kapidox-$pkgver.tar.xz"
subpackages="$pkgname-doc"

build() {
	cmake -B build \
		-DCMAKE_BUILD_TYPE=None \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib \
		-DBUILD_QCH=ON
	cmake --build build
}

check() {
	cd build
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
}

package() {
	DESTDIR="$pkgdir" cmake --build build --target install
}
sha512sums="72343766922641e9fb86c360e8d3f165a6ee3743af3a6abea2be0dc75cf2708ff539fff07e5318dc7ad9ad0101d90efd0f3fd2e42da6826edf89abc94ecf4fd1  kapidox-5.73.0.tar.xz"
